Skip to content

Allow GitHub bot to load repository code to Doublets store on default branch commits - #320

Open
konard wants to merge 3 commits into
mainfrom
issue-76-7bb976ea
Open

Allow GitHub bot to load repository code to Doublets store on default branch commits#320
konard wants to merge 3 commits into
mainfrom
issue-76-7bb976ea

Conversation

@konard

@konard konard commented Sep 13, 2025

Copy link
Copy Markdown
Member

Summary

  • Implemented a CommitTracker that monitors commits to default branches of organization repositories
  • Created LoadRepositoryCodeToDoubletsTrigger that automatically loads repository code into the Doublets store when new commits are detected
  • Extended GitHubStorage with methods to retrieve repository contents from GitHub API
  • Integrated the new functionality into the main bot loop in Program.cs

Key Features

  • Automatic code loading: Each commit to default branch triggers code snapshot update in the links store
  • File filtering: Skips binary files and large files (>1MB) to optimize storage
  • Recursive directory processing: Loads entire repository structure
  • File set organization: Code is organized by repository in named file sets (e.g., "linksplatform/Bot")
  • Error handling: Graceful handling of repository access issues and file processing errors

Technical Implementation

The solution follows the existing bot architecture patterns:

  • CommitTracker implements ITracker<GitHubCommit> and polls for recent commits
  • LoadRepositoryCodeToDoubletsTrigger implements ITrigger<GitHubCommit> and processes each commit
  • Repository content is stored in the Doublets store using the existing FileStorage abstraction
  • Integration with existing GitHub API wrappers in GitHubStorage

Test Plan

  • Build verification - solution compiles without errors
  • Unit test - created test script to verify Doublets storage functionality
  • Integration ready - new tracker is integrated into main bot loop

The implementation is ready for deployment and will start loading repository code snapshots on the next bot cycle after merge.

🤖 Generated with Claude Code


Resolves #76

Adding CLAUDE.md with task information for AI processing.
This file will be removed when the task is complete.

Issue: #76
@konard konard self-assigned this Sep 13, 2025
… commits

- Add CommitTracker for monitoring repository commits
- Create LoadRepositoryCodeToDoubletsTrigger for loading repository content to Doublets store
- Extend GitHubStorage with methods to retrieve repository contents
- Update Program.cs to include the new commit tracking functionality
- Add test experiments to verify functionality

Each commit to the default branch now updates the code snapshot in the links store, making repository code available for analysis and processing through the Doublets system.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@konard konard changed the title [WIP] Allow the GitHub bot to load the code from repository to Doublets store Allow GitHub bot to load repository code to Doublets store on default branch commits Sep 13, 2025
@konard
konard marked this pull request as ready for review September 13, 2025 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow the GitHub bot to load the code from repository to Doublets store

1 participant